<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>js_test</title>
<script type="text/javascript" src="jstest.js"></script>
<script type="text/javascript">
/*	var obj = new Object();
	obj.name = "yuexin";
	obj.id = '1001';
	obj.age = 23;
	for(var v in obj){
		alert(obj[v]);
		}*/
		//var dd = window.setInterval("alert('ddd');",2000);
		
		window.onmousemove = function(){
				document.getElementById("pointer").innerHTML ="X:" + event.pageX +" Y:" +event.pageY;
			}
			
		function fun(){
			window.location.href = "http://www.baidu.com";
			window.location.reload;
			}
			
			var i = 1;
		window.onload = function(){
			window.setInterval("dd()",50);
			form.name.focus();	
			}
			
			function dd(){
				var str = "";
				if(i == 100){
					i = 1;
					}
				for(j = 0; j<i; j++){
					str+=" ";
					}
					window.status = str + "<a href = 'http://www.baidu.com'>百度</a>";
					i++;
				}
			
/*alert(confirm("message")) ;
alert(window.prompt('姓名',''));*/

/*var test1="http://www.w3school.com.cn/My first/index.html?name=南美鹰"
var test2 = encodeURI(test1);
var test3 = decodeURI(test2);
document.write(test2 +"<br/>");
document.write(test3+"<br/>");
var test4 = "南美鹰";
var test5 = escape(test4);
var test6 = unescape(test5);
document.write(test5 + "   "+ test6 + "<br/>");

var str="Hello worldworldworld!"
document.write(str.match(/world/g) + "<br />")



var arr = new Array(3)
arr[0] = "George"
arr[1] = "John"
arr[2] = "Thomas"
document.write(arr + "<br />")
document.write(arr.reverse())
document.write(arr)

document.write("<br />")

document.write(arr.pop())

document.write("<br />")

document.write(arr)*/

/*var str = "Visit W3School.com.cn";
var patt1 = new RegExp("W3S","g");

document.write("The regular expression is: " + patt1.source);*/


/*var str="Hello world!"
document.write(str.strike())*/

/*var p = new Object();
p.id = '1';
p.name = 'nanmeiying';
p.birthday = new Date();
document.write("id=" + p.id + " name=" + p.name + " birthday="+p.birthday.toLocaleDateString() + "<br/>");
*/		

/*var nu = window.prompt("input a num",'');
if(isNaN(nu)){
	alert("not a num");
	}*/
	


</script>
</head>

<body>


<button onclick="fun();">click</button>
<form id="form" name="myform" action="#" method="post" enctype="multipart/form-data" onsubmit="alert('tijiao');" >
 
 <input type="radio" id="radio1" />
<input type="button" onclick="radio1.checked=true" value="Check" />
<input type="button" onclick="radio1.checked=false" value="Uncheck" />

 
 
 
 
 
 
 
 
 
 
 
 
 
  姓名：
  <input type="text" name="name"/>
  <br/>
  性别:
  <input type="radio" name="sex" value="nan"  />
  男
  <input type = "radio" name="sex" value="nv" checked="checked"/>
  女<br/>
  爱好:
  <input type="checkbox" name="hobby" value="java"/>
  java
  <input type="checkbox" name="hobby" value="css" checked="checked"/>
  css
  <input type="checkbox" name="hobby" value="js" />
  js<br/>
  国家:
  <select name="country" onchange="alert(this.value);">
    <optgroup label="欧洲">
    <option label="英国" value="uk"/>
    <option label="意大利" value="ita"/>
    </optgroup>
    <optgroup label="亚洲" >
    <option label="中国" value="china" selected="selected"/>
    <option label="韩国" value="hg"/>
    </optgroup>
  </select>
  <br/>
  <input type="submit" value="submit"/>
</form>
<div id="pointer"> </div>
</body>
</html>
